module.exports = function goAwait(promise) {
    if (!promise || !Object.prototype.isPrototypeOf.call(Promise, promise)) {
        return new Promise(function (resolve, reject) {
            reject(new Error('requires promises as the param'));
        })["catch"](function (err) {
            return [err, null];
        });
    }
    return promise.then(function (payload) { return [null, payload]; })["catch"](function (err) { return [err, null]; });
};
